package org.example.demo.controller;

import org.example.demo.dao.OrderDao;
import org.example.demo.entity.OrderEntity;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.graphql.data.method.annotation.Argument;
import org.springframework.graphql.data.method.annotation.QueryMapping;
import org.springframework.stereotype.Controller;

import java.math.BigDecimal;
import java.util.*;

@Controller
public class HelloController {
    @Autowired
    private OrderDao orderDao;

    @QueryMapping
    public OrderEntity getOrderById(@Argument int id) {
        return orderDao.selectById(id);
    }


}
